#ifndef GINTERPRETER_H
#define GINTERPRETER_H

#include <QObject>
#include <QDebug>
#include "MotionPath.h"

class GInterpreter : public QObject
{
    Q_OBJECT
public:
    explicit GInterpreter(QObject *parent = 0);
    int interpret(QString gcode, MotionPath* path);

signals:

public slots:

private:
    QString _gcode;
    MotionPath* _path;
    Block block;
    Setup settings;

    int parse(QString line);
    int read_items(QString line);
    int read_one_item(QString line, int &count);
    int execute();
};

#endif // GINTERPRETER_H
